package com.modelscope.ai.service;

import com.modelscope.ai.domain.entity.AiEntity;
import com.modelscope.ai.domain.entity.ChatEntity;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@Service
@FeignClient(name = "chat", url = "${chat.url}")
public interface ChatService {

    @PostMapping(value = "/encoder", consumes = {MediaType.MULTIPART_FORM_DATA_VALUE})
    String encoder(@RequestBody ChatEntity aiEntity);

}
